import { List, Switch } from 'antd';
import React from 'react';

export default () => {
  const getData = () => {
    const Action = (
      <Switch
        checkedChildren='开'
        unCheckedChildren='关'
        defaultChecked
      />
    );
    return [
      {
        title: '告警消息',
        description:'系统消息将以站内信的形式通知',
        actions: [Action],
      },
      {
        title: '系统消息',
        description:'系统消息将以站内信的形式通知',
        actions: [Action],
      },
      {
        title: '代办任务',
        description:'系统消息将以站内信的形式通知',
        actions: [Action],
      },
    ];
  };

    return (
      <React.Fragment>
        <List
          itemLayout="horizontal"
          dataSource={getData()}
          renderItem={(item) => (
            <List.Item actions={item.actions}>
              <List.Item.Meta title={item.title} description={item.description} />
            </List.Item>
          )}
        />
        </React.Fragment>
    );
}
